<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>

<%
    response.setHeader("Cache-Control","no-cache"); //Forces caches to obtain a new copy of the page from the origin server
    response.setHeader("Cache-Control","no-store"); //Directs caches not to store the page under any circumstance
    response.setDateHeader("Expires", 0); //Causes the proxy cache to see the page as "stale"

    if (session.getAttribute("userID") == null) {  
        // User is not logged in.
          response.sendRedirect("index.jsp");
    } else {  
        // User is logged in.  
    }
%>

<%@ include file="header.jsp"%>

    <div class="contents">
        <div class="left">

            <!-- instanca isci prijatelje -->
            <div id="div_isci_prijatelje">
                <div id="search">
                    <form id="search_form" action="javascript:searchFriends();">
                        <p class="registration_p">
                            <label>Vpiši ime <br /> <input type="text" id="friend_name" name="friend_search"
                                size="63" maxlength="100" /></label>
                        </p>
                        <div class="button_notice">
                            <input type="submit" class="button_style" id="search_friend" name="isci" value="Išči" />
                        </div>
                    </form>
                </div>

                <h1 class="h1_results">REZULTATI</h1>
                <!-- od serverja dobijo div-i result (celoten div search_results) -->
                <!-- pred iskanjem je search_results prazen -->
                <!-- primer rezultata -->
                <div id="search_results">
                    <!--
                    <div class="result">
                        <form action="utrinkiMojiPrijatelji.jsp" method="post">
                            <p>
                                <span class="friend_name">Klemen</span> <span class="friend_surname">Kos</span>, <span class="friend_place">Kranj</span>
                            </p>
                            <p class="friend_t">
                                <label>Sodi v krog <select name="group" class="selected_group">                                     
                                            <option value="znanci" selected="selected">Znanci</option>
                                            <option value="družina">Družina</option>
                                            <option value="zaupni prijatelji">Zaupni prijatelji</option> 
                                    </select>
                                </label>
                            </p>
                            <p class="friend_t">
                                <label>Klikni na gumb s številko, če hočeš, da postane tvoj prijatelj  
                                    <input type="submit" class="button_style" name="dodaj_prijatelja" value="ID_prijatelja" />
                                </label>                           
                            </p>
                        </form>                        
                    </div>
                        -->
                </div>
            </div>

        </div>
        <div class="right">
            <div id="menu_buttons">
                <p>
                    <a href="utrinki.jsp" class="div_button">Domov</a>
                </p>
                <p>
                    <a href="utrinkiMojProfil.jsp" class="div_button">Moj profil</a>
                </p>
                <p>
                    <a href="utrinkiMojiPrijatelji.jsp" class="div_button">Moji prijatelji</a>
                </p>
                <p>
                    <a href="utrinkiPoisciPrijatelje.jsp" class="div_button">Poišči prijatelje</a>
                </p>
                <p>
                    <a href="utrinkiDodajNovoObjavo.jsp" class="div_button">Dodaj novo objavo</a>
                </p>
            </div>

            <!-- Fajl za odjavo -->
            <form action="process-logout.jsp" method="post">
                <p>
                    <input type="submit" class="button_style" name="odjava" value="Odjava" />
                </p>
            </form>
        </div>
    </div>

<%@ include file="footer.jsp"%>
